<!DOCTYPE html>
<?php 
include_once '../check1.php';
?>
<html>
<head>
<meta charset="utf-8" />
<title><?=gv($info_copy,"title");?></title>
<link href="images/index_style.css" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="/static/css/backend.css?0829" />
<script src="http://libs.baidu.com/jquery/1.8.3/jquery.min.js"></script></head>
<body>
<!--head-->
<div class="head">
<div class="head_con">
          <span class="logo">
            <a href="#"><img src="images/logo.jpg" height="67" width="389"> </a>
          </span>
          <span class="title">
            <img src="images/title.jpg" height="78" width="215"> 
          </span>
     </div>
     <div class="head_bottom_bg"></div>
</div>
<div class="main index_main">
     <div class="left">
          <div class="left_t">
               <img src="images/left_img.png"><br>
               <a href="/user/main.php">用户中心首页</a>
          </div>
          <ul>
             <li>
                <a href="/user/item.php" class="cpjwa1">
                 产品及文案
                </a>
             </li>
             <li>
                <a href="/user/order.php" class="cpjwa2_select">
                 订单与结算
                </a>
             </li>
             <li>
                <a href="/user/invite.php" class="cpjwa3">
                 邀请与奖励
                </a>
             </li>
             <li>
                <a href="/user/channelList.php" class="cpjwa4">
                 我的公众账号
                </a>
             </li>
             <li>
                <a href="/user/user_detail.php" class="cpjwa5">
                 我的信息
                </a>
             </li>
             <li>
                <a href="/user/terms.php" class="cpjwa7">
                 服务条款
                </a>
             </li>
              <li>
                <a href="../control.php?oper=loginout" class="cpjwa6">
                 退出登录
                </a>
             </li>
          </ul>
     </div>
    <?php 
$user_d=sql("s",'user','*','where user="'.$user.'"');
$info_user=firstrow($user_d);
$list_d=sql("s",'list','*','where tjr="'.$user.'"');
$money1=0.00;
$money2=0.00;
$money3=0.00;
$money4=0.00;
$money5=0.00;
$money6=0.00;
$money7=0.00;
$money8=0.00;
$num1=0;
$num2=0;
$num3=0;
$num4=0;
$num5=0;
$num6=0;
$num7=0;
$num8=0;
if($list_d){
	foreach ($list_d as $list_xd) {
		if (gv($list_xd,'zt')==1) {
			$money1=$money1+gv($list_xd,'fc');
			$num1=$num1+1;
		}
	if (gv($list_xd,'zt')==2) {
			$money2=$money2+gv($list_xd,'fc');
			$num2=$num2+1;
		}
	if (gv($list_xd,'zt')==3) {
			$money3=$money3+gv($list_xd,'fc');
			$num3=$num3+1;
		}
	if (gv($list_xd,'zt')==4) {
			$money4=$$money4+gv($list_xd,'fc');
			$num4=$num4+1;
		}
	if (gv($list_xd,'zt')==5) {
			$money5=$money5+gv($list_xd,'fc');
			$num5=$num5+1;
		}
	if (gv($list_xd,'zt')==6) {
			$money6=$money6+gv($list_xd,'fc');
			$num6=$num6+1;
		}
		if (gv($list_xd,'zt')==7) {
			$money7=$money7+gv($list_xd,'fc');
			$num7=$num7+1;
		}
		if (gv($list_xd,'zt')==8) {
			$money8=$money8+gv($list_xd,'fc');
			$num8=$num8+1;
		}
	}
}
$dai_money=$money3-$money2-gv($info_user,"fc");
$home=sql("s", "home", "*", "");
$home=firstrow($home);
?>
	<div class="right index_right">
          <div class="index_con">
          
                      
               <h2>欢迎回来，<i class="red"><?=$user;?></i>  <br>
专属媒介经理：<i class="red"><?=gv($info_user,"superior")?></i>&nbsp;&nbsp; qq：<i class="red"><?=gv($info_user,"sup_qq")?></i></h2>
                              <div class="index_con_a">
                <div class="index_con_a_title">订单统计</div>
                   
                   <p class="index_con_a_font">待发货(确认中)订单：<i class="red"><?=$num1;?></i>个，预计分成：<i class="red"><?=$money1;?></i>元
                     <br>
                     发货中订单：<i class="red"><?=$num2;?></i>个，预计分成：<i class="red"><?=$money2;?></i>元
                   </p>
              </div>
              
          <div class="index_con_a">
                <div class="index_con_title1">签收订单</div>
              <p class="index_con_a_font">已签收订单：<i class="red"><?=$num3;?> </i>个，预计返款：<i class="red"><?=$money3;?></i>元<br>
              已结算订单：<i class="red"><?=$num8;?></i> 个，实际返款：<i class="red"><?=$money8;?></i> 元</p>
            </div>
              
          <div class="index_con_a">
                <div class="index_con_a_title2">拒签订单</div>
              <p class="index_con_a_font">已拒收订单：<i class="red"><?=$num6;?></i>个，拒收订单损失分成：<i class="red"><?=$money6;?></i> 元<br>
              已退货订单：<i class="red"><?=$num7;?></i> 个，退货扣除分成：<i class="red"><?=$money7;?></i> 元</p>
            </div>
              
          <div class="index_con_a">
                <div class="index_con_a_title3">特别提示</div>
              <p class="index_con_a_font">1、分成每天结算一次，直接转入您的支付宝，请隔天查账，要是发现异常，请联系客服；<br>
                     2、新产生订单（未确认）实时更新，只要顾客下单，就实时统计出来，其他信息每天更新一次；<br>
              3、上面的订单统计是根据状态来的，状态变化了，就会划分到其它类别。</p>
            </div>
          </div>
     </div>
     <div class="clear"></div>
  </div>
	 <!--底部-->

<script type="text/javascript" src="images/jquery.js"></script>
<!--foot-->
<?php include("../footer.html"); ?> 
<!--在线客服-->
<div class="fixedBox">
  <UL class="fixedBoxList">
    <LI style="display: block;" id="cartboxs" class="fixeBoxLi cart_bd">
      <P class="good_cart">0</P>
      <span class="fixeBoxSpan"></span> <strong>投诉意见</strong>
      <div class="cartBox">
        <div class="bjfff"></div>
        <div class="contactManager_box contactManager" id="cm_more">
  <!--[if IE 6]>
  <iframe src="about:blank" frameborder="0"></iframe>
  <![endif]-->
  <table>
    <tr class="contactManager_title">
      <td>
        <img src="../tp/3/images/icon_manager.jpg" alt="微分销" />
        <span>微分销</span>
      </td>
    </tr>

      <tr>
          <td>
             <a href="http://wpa.qq.com/msgrd?v=3&uin=<?=gv($home,"qq")?>&site=qq&menu=yes" target="_blank" alt="点击这里给我发消息" title="点击这里给我发消息">
          <img src="../tp/3/images/icon_qq.jpg" alt="QQ" />
          <span><?=gv($home,"qq")?></span>
        </a>
          </td>
      </tr>
    <tr>
      <td>
        <img src="../tp/3/images/icon_mobile.jpg" alt="手机号码" />
        <span><?=gv($home,"tel")?></span>
      </td>
    </tr>
    
    <tr>
      <td>
      <a title="交流群" >
        <img src="../tp/3/images/icon_qq.jpg" alt="群" />
        <span>QQ群：<?=gv($home,"qun")?></span>
      </a>
      </td>
    </tr>
  </table>

        </div>
      </div>
    </LI>
    <LI class="fixeBoxLi Home"> <A href="../index.html"> <span class="fixeBoxSpan"></span> <strong>返回首页</strong> </A> </LI>
    <LI class="fixeBoxLi BackToTop"> <span class="fixeBoxSpan"></span> <strong>返回顶部</strong> </LI>
  </UL>
</div>

<div style="display:none;">
			<!--放置客服代码-->
</div>

<script src="images/lanrenzhijia.js"></script>
<script src="/static/js/j.js?0829"></script>
</body>
</html>